package day1220;

public class Test3 {

    public static void main(String[] args) {
        System.out.println(Math.random());

        double rs=Math.random();
        System.out.println(rs);
    }


/*    public static void main(String[] args) {
        Scanner s=new Scanner(System.in);
        System.out.println(请输入第一个整数：);
        int a=s.nextInt();
        System.out.println(请输入第一个整数：);
        int b=s.nextInt();
        int rs=addTwo(a, b);
        System.out.println(rs);

        变量类型  变量名=addTwo(a, "*", b);
        System.out.println(变量名);
    }



    //方法内：    用return 返回一个数值
    //方法的返回值类型就需要更换void,
    private static String addTwo(double a,    String operator,    double b){
        if(operator.equals("+")){
            return a+b+"";
        }else if(operator.equals("-")){
            return a-b+"";
        }else if(operator.equals("*")){
            return a*b+"";
        }else if(operator.equals("/")){
            return a/b+"";
        }else{
            return "运算符无效";
        }
    }*/




}
